package asteroids.model.programs.binaryexpression;

import asteroids.model.programs.Expression;
import asteroids.model.programs.Program;
import exception.IllegalOperandException;

public class Substraction extends BinaryExpression<Double> {

	public Substraction(Expression<?> left, Expression<?> right)
			throws IllegalOperandException {
		super(left, right);
	}

	@Override
	public Double getValue(Program program) {
		return ((Double)getLeftOperand().getValue(program)) - ((Double)getRightOperand().getValue(program));
	}



}
